package com.coin900.coin.service.coin;

import com.coin900.coin.persist.coin.CoinProjectVO;
import com.coin900.coin.persist.coin.CoinUserProjectVO;
import com.value.mybatis.Pagination;

import java.util.List;
import java.util.Map;

/**
 * 项目
 *
 * @author shui
 * @create 2018-1-14
 */
public interface ICoinProjectService {

    List<CoinProjectVO> loadCoinProject(Map<String, Object> params);

    /**
     * 条件查询用户购买了的项目
     *
     * @param params
     * @return
     */
    List<CoinUserProjectVO> loadUserProject(Map<String, Object> params);

    List<CoinUserProjectVO> loadUserProjectForPage(Pagination pagination);

    List<CoinProjectVO> loadCoinProjectForPage(Pagination pagination);

    void insertCoinProject(CoinProjectVO coinProjectVO);

    void updateCoinProject(CoinProjectVO coinProjectVO);

    /**
     * 支付订单-增加项目筹集资金，增加认筹人数
     *
     * @param coinProjectVO
     */
    void doPayForTheOrder(CoinProjectVO coinProjectVO);

    void deleteCoinProject(CoinProjectVO coinProjectVO);

}